﻿using System.ComponentModel.DataAnnotations;
using IdeaBlade.EntityModel;
using IdeaBlade.Validation;
using SWTORLogDb.Entities.SWTOR.CombatLogs;
using SWTORLogDb.Enums;

namespace SWTORLogDb.Entities.SWTOR
{
    public class Character : AuditEntityBase
    {
        public int CharacterId { get; set; }

        [Required]
        public SWTORRace Race { get; set; }

        [Required]
        public SWTORClass Class { get; set; }

        [Required]
        public SWTORSubClass SubClass { get; set; }

        [Required]
        [Int32RangeVerifier(MinValue = 1, MaxValue = 50)]
        public int Level { get; set; }

        [Int32RangeVerifier(MinValue = 0, MaxValue = 10)]
        public int SocialLevel { get; set; }

        [Int32RangeVerifier(MinValue = 0, MaxValue = 100)]
        public int ValorLevel { get; set; }

        public int GuildId { get; set; }
        public Guild Guild { get; set; }

        [Required]
        public int ServerId { get; set; }
        public Server Server { get; set; }

        [Required]
        public int PlayerId { get; set; }
        public Player Player { get; set; }

        public RelatedEntityList<SoloEncounter> SoloEncounters { get; set; }

        public RelatedEntityList<OperationAttendance> Operations { get; set; } 

        public RelatedEntityList<CharacterCrewSkill> CrewSkills { get; set; }
    }
}
